#!/bin/bash
cd /usr/local
wget https://studygolang.com/dl/golang/go1.19.11.linux-amd64.tar.gz
tar -zxvf go1.20.6.linux-amd64.tar.gz
mkdir /usr/local/gopath
echo -e "export GOROOT=/usr/local/go\nexport GOPATH=/usr/local/gopath\nexport PATH=\$PATH:\$GOROOT/bin:\$GPPATH/bin" >> /etc/profile
source /etc/profile